package com.java1412.service.impl;

import com.alibaba.dubbo.config.annotation.Service;
import com.java1412.entity.UserAddress;
import com.java1412.service.UserService;

import java.util.Arrays;
import java.util.List;

/**
 * @author java1412
 * @create 2021-07-02 10:23
 */
@Service    // 使用dubbo提供的service注解，注册暴露服务
public class UserServiceImpl implements UserService {

    // @Autowired
    // private  UserAddressMapper userAddressMapper;

    public List<UserAddress> getUserAddressList(String userId) {
        System.out.println("UserServiceImpl..." + userId);
        UserAddress address1 = new UserAddress(1, "南京市", "1", "李老师", "025-56253825", "Y");
        UserAddress address2 = new UserAddress(2, "上海市", "1", "王老师", "011-56253825", "N");
        return Arrays.asList(address1, address2);
    }
}
